#include "StdAfx.h"
#include "wnd_capture_ex_impl.h"

wnd_capture_ex_impl::wnd_capture_ex_impl(void)
{
	AFX_MANAGE_STATE(AfxGetStaticModuleState());

	this->wnd_cap_.CreateEx(WS_EX_TOOLWINDOW | WS_EX_NOPARENTNOTIFY, 
		NULL, NULL, WS_CHILD, 12, 30, 0, 0, CWnd::GetDesktopWindow()->m_hWnd, NULL);
}

wnd_capture_ex_impl::~wnd_capture_ex_impl(void)
{
	AFX_MANAGE_STATE(AfxGetStaticModuleState());

	this->wnd_cap_.DestroyWindow();
}

BOOL wnd_capture_ex_impl::capture(HWND notify_wnd)
{
	AFX_MANAGE_STATE(AfxGetStaticModuleState());

	return this->wnd_cap_.capture(notify_wnd);
}

BOOL wnd_capture_ex_impl::set_pic_savepath(const char* ptr_dir)
{
	AFX_MANAGE_STATE(AfxGetStaticModuleState());

	return this->wnd_cap_.set_pic_save_path(ptr_dir);
}


/// basic check by fan05